<template>
  <div>
    123
    <!-- 消息提示类
   1：完整写法
      this.$message({
        type:'success/error/warning/info',
        message:'提示内容'
      })
   2：简写:
      this.$message.type的值(success/error/warning/info)('消息内容')

-->
    <el-button @click="btnClick1">成功</el-button>
    <el-button @click="btnClick2">错误</el-button>
  </div>
</template>
<script>
export default {
  methods: {
    btnClick1() {
      this.$message({
        type: 'success',
        message: '登录成功'
      })
    },
    btnClick2() {
      this.$message.error('登录失败')
    }
  }
}
</script>
<style></style>
